using System;
using System.Collections.Generic;
using System.Text;

using Entities;
using IDAL;

namespace Bll
{
    public class ReviewBll
    {
        public bool Delete(ReviewInfo review)
        {
            IReviewDAO dal = (IReviewDAO)AssemblyLoader.Load("ReviewDAO");
            return dal.Delete(review);
        }

        public IList<ReviewInfo> GetAll()
        {
            IReviewDAO dal = (IReviewDAO)AssemblyLoader.Load("ReviewDAO");
            return dal.GetAll();
        }

        public IList<ReviewInfo> GetByProductID(string productID)
        {
            IReviewDAO dal = (IReviewDAO)AssemblyLoader.Load("ReviewDAO");
            return dal.GetByProductID(productID);
        }

        public bool Insert(ReviewInfo review)
        {
            IReviewDAO dal = (IReviewDAO)AssemblyLoader.Load("ReviewDAO");
            return dal.Insert(review);
        }
    }
}
